package repository;


import java.rmi.Remote;
import java.rmi.RemoteException;
import java.util.ArrayList;

/**
 * Interface to the repository from which instruments fetch their music.
 * @author 0800542m, 0807932b
 *
 */
public interface Repository extends Remote {
	
	/**
	 * Used by instruments to retrieve the music that will be played.
	 * @param instrumentNum Number representing the instrument type.
	 * @return An arraylist of bars, each containing notes to be played by the instrument.
	 * @throws java.rmi.RemoteException
	 */
	public ArrayList<ArrayList<Note>> getMusic(int instrumentNum) throws java.rmi.RemoteException;
	
	/**
	 * Used by conductor to get the overall song length.
	 * @return Length of song in bars as an integer.
	 * @throws java.rmi.RemoteException
	 */
	public Integer getSongLength() throws java.rmi.RemoteException;
	
	/*
	 * Used by Monitor to assign the correct instrument to each player
	 */
	public Integer getNumInstruments() throws RemoteException;
}
